Dont' null deref notes.
authorrobertl <robertl@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Sat, 26 Apr 2003 23:43:36 +0000 (23:43 +0000)
committerrobertl <robertl@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Sat, 26 Apr 2003 23:43:36 +0000 (23:43 +0000)
gpsbabel/csv_util.c

index 84c00348b056331ddb2d5d2546a6222d940396ed..f9ef0481455a2f74f84c516c4778bb11ce110089 100644 (file)
@@ -653,7 +653,7 @@ xcsv_waypt_pr(const waypoint *wpt)
             sprintf(buff, fmp->printfc, description);
         } else
         if (strcmp(fmp->key, "NOTES") == 0) {
-            sprintf(buff, fmp->printfc, wpt->notes);
+           sprintf(buff, fmp->printfc, wpt->notes? wpt->notes : "");
         } else
         if (strcmp(fmp->key, "URL") == 0) {
            int off = 0;